import request from '../request'
import { getStore } from '../../config/mUtils'
export default {
  // eslint-disable-next-line camelcase
  async login (username, password, captcha_code) {
    return await request.post('/v2/login', { username, password, captcha_code })
  },
  async getcaptchas () {
    return await request.post('/v1/captchas')
  },
  async getUser () {
    return await request.get('/v1/user', { user_id: getStore('user_id') })
  },
  async signout () {
    return await request.get('/v2/signout')
  }
}
